import Bg from '../public/bg.jpg'
import SkipImg from '../public/skip.png'
import TopImg from '../public/top.png'
import CenterFrameImg from '../public/centerFrame.png'
import FrameTopImg from '../public/frameTop.png'
import BoyImg from '../public/boy.png'
import GirlImg from '../public/girl.png'
import GirlSayImg from '../public/girlSay.png'
import LeftHandImg from '../public/leftHand.png'
import RightHandImg from '../public/rightHand.png'
import LeftHeiImg from '../public/leftHei.png'
import RightHeiImg from '../public/rightHei.png'
import BigHeiImg1 from '../public/bigHei1.png'
import BigHeiImg2 from '../public/bigHei2.png'
import BigHeiImg3 from '../public/bigHei3.png'
import MoneyImg from '../public/money.png'

$('.bg').attr('src', Bg)
// $('.skipImg').attr('src', SkipImg)
$('.topImg').attr('src', TopImg)
$('.centerFrameImg').attr('src', CenterFrameImg)
$('.frameTopImg').attr('src', FrameTopImg)
$('.boyImg').attr('src', BoyImg)
$('.girlImg').attr('src', GirlImg)
$('.girlSayImg').attr('src', GirlSayImg)
$('.leftHandImg').attr('src', LeftHandImg)
$('.rightHandImg').attr('src', RightHandImg)
$('.leftHeiImg').attr('src', LeftHeiImg)
$('.rightHeiImg').attr('src', RightHeiImg)
$('.moneyImg').attr('src', MoneyImg)

var handTime = 1
var transform
//左右两只手的动画
setInterval(function(){
  handTime = -handTime
  handTime == -1 ? $('.leftHandImg').addClass('leftHandShake') : $('.leftHandImg').removeClass('leftHandShake')
  handTime == -1 ? $('.rightHandImg').addClass('rightHandShake') : $('.rightHandImg').removeClass('rightHandShake')
},700)

var heiTime = 0
var heiFlag = 1
var heiImgs = [BigHeiImg1, BigHeiImg2, BigHeiImg3]
//大嘿的动画
setInterval(function(){
  heiTime += heiFlag
  if(heiTime >= 2){
    heiFlag = -1
  }
  if(heiTime <= 0){
    heiFlag = 1
  }
  $('.bigHeiImg').attr('src', heiImgs[heiTime])
}, 600)



